var offsetX = $("#loveHeart").width() / 2;
var offsetY = $("#loveHeart").height() / 2 - 55;

if (!document.createElement('canvas').getContext) {
	var msg = document.createElement("div");
	msg.id = "errorMsg";
	msg.innerHTML = "Your browser doesn't support HTML5!<br/>Recommend use Chrome 14+/IE 9+/Firefox 7+/Safari 4+";
	document.body.appendChild(msg);
	$("#code").css("display", "none")
	$("#copyright").css("position", "absolute");
	$("#copyright").css("bottom", "10px");
	document.execCommand("stop");
} else {
	setTimeout(function() {
		adjustWordsPosition();
		startHeartAnimation();
	}, 10000);

	$("#accept").click(function() {
		$(this).hide();
		$("#elapseClock").show();
		var together = new Date();
		timeElapse(together);
		setInterval(function() {
			timeElapse(together);
		}, 500);
	})
	adjustCodePosition();
	$("#code").typewriter();
}
